Currently, with evolution of the network, specifically with huge applications on streaming media, there is a demand for a higher and differentiated performance of Quality of Service (QoS) in the network. No matter which policy is adopted to realize the QoS of the network, finally at several key nodes of the network, it should be capable of scheduling a plurality of sources to be scheduled (the source is generally a queue), based on pre-configured parameters (bandwidth, jitter, etc.), and transmitting data selected from an appropriate queue. When congestion occurs and packets need to be discarded, then the packets are discarded based on pre-configured parameters of Committed Information Rate/Peak Information Rate (CIR/PIR) priority, etc.
There are diverse selections on several queues scheduling, for example, Strict-Priority Queue (PQ) scheduling, Round Robin (RR) scheduling, improved Weighted Round Robin (WRR) scheduling, Weighted Fair Queue (WFQ) scheduling, etc. No matter which scheduling method is utilized, backpressure is always a headache. As to scheduling a plurality of queues, generally, reservation for bandwidth needs to be configured, for example, the bandwidth of queue A is 10 Mbps, the bandwidth of queue B is 1 Gbps, the bandwidth of queue C is 200 Mbps, etc. To achieve line rate forwarding performance, the sum of all reserved bandwidth of the queues may exceed or be equal to the final export bandwidth. At this time, there is a new inevitable problem caused by burst traffic or schedule offset, etc., i.e. the total allowable export traffic (1 Gbps or 2.5 Gbps, for example, which is limited to actual physical export,) is lower than the sum of actual bandwidth of all queues. As such, it is impossible to satisfy the actual bandwidth of all queues. A desirable instance may be as follow.
In a first instance, if total bandwidth of actual data does not exceed total export bandwidth, then it is desirable to perform scheduling based on the reserved bandwidth which is actually configured, and no backpressure occurs.
In a second instance, if transient burst traffic occurs on the actual data, which exceeds the total export traffic during some time period, at this time, caching may be performed in the export queues after export congestion occurs. When total bandwidth of the actual data is lower than export bandwidth, data in the cache may be transmitted, and also no backpressure occurs at this time.
In a third instance, if total bandwidth of actual data is always higher than total export bandwidth during quite a long time, then backpressure may occur. However, it is desirable that backpressure has effects on all queues participating in scheduling, and moreover, it is better to assign the effects according to reserved bandwidth proportion. That is to say, the actual scheduling bandwidth of queues participating in scheduling is better to shrink according to the reserved bandwidth proportion. Not all queues participate in bandwidth assigning. Rather, bandwidth assigning is performed among queues with actual data which are to be scheduled.
Currently, conventional standard QOS scheduling module is illustrated as FIG. 1, with four levels of scheduling in all. Firstly, different services are identified among users internally, and WFQ+SP (Strict Priority) scheduling is performed among different services. Then, CIR/PIR may be configured by the user, i.e. a committed bandwidth is provided for the user, and to a certain extent, burst traffic of user is allowed to pass. Next, the user may be mapped to different priority queues in the ports or different internal services of the user may be mapped to priority queues in the ports, and the priority levels are scheduled according to PQ scheduling. Finally, RR scheduling or WRR scheduling is performed among the ports. A module which accomplishes QOS function as illustrated in FIG. 1 may be referred to as a traffic management module. Generally, number of ports is in accordance with number of physical channels. Backpressure of physical channels may be delivered directly to ports. Then the ports deliver backpressure reversely in turn. At this time, the packets are cached in the traffic management module. When cache is full, the packets are discarded according to parameters of priority, CIR or PIR configured by the user, etc. In the case of guaranteeing user CIR, ensure that packets with high priority are scheduled first and packets with low priority are discarded first. Currently, conventional art usually inquires transmitting First In First Out (FIFO) status actively from a physical transmitting port via a traffic management module, or the physical transmitting port feeds back transmitting FIFO status actively to the traffic management module. If the transmitting FIFO exceeds backpressure threshold, the physical transmitting port outputs a backpressure signal to the traffic management module. The traffic management module stops transmitting and then caches packets in the scheduling queue. If the queue is full, then the packets are discarded according to the pre-configured parameters.
When there are too many physical channels, (for example, channelized POS (packet over SDH/SONET; where: SDH represents Synchronous Digital Hierarchy; SONET represents Synchronous Optical NETwork) ports may have 1 k physical ports), when egress of the traffic management module, for example, SPI4.2 port may only support 256 channels of backpressure signals, cannot respond to backpressure of all channels, negative feedback of backpressure cannot be formed. That is, according to the existing solution and interface specification, backpressure signals of masses of ports cannot be transmitted. Then, according to the existing technique, the egress rate is limited only through open loop control, i.e. shaping egress to limit its egress rate to be less than or be equal to physical port rate. With this technique, backpressure of physical channel is avoided, and fluctuation resulted from traffic variation is solved within the traffic management module internally. This method has three problems in actual application:
Common traffic management module inevitably has scheduling offset as to some packets with a fixed length when performing traffic scheduling. Such scheduling offset may cause transmitting queue congestion in physical ports, i.e. it may discard the packets when physical egress queue is full. Thus, configured parameters of user CIR and priority, etc. cannot be guaranteed.
In addition, shaping granularity of egress may not satisfy practical requirements, for example, the bandwidth of a low speed port is 64 k while the shaping granularity of egress is 20 k. If line rate of port is guaranteed, then shaping PIR has to be configured at 80 k. If there is no response to the backpressure, the packets may be discarded. At this time, discarding packets on the physical ports usually has to be performed as tail discarding or discarding according to the absolute priority. Thus, the configured parameters of user CIF and priority, etc. cannot be guaranteed.
Moreover, current channels transmitting backpressure signals of masses of ports are customized backpressure state bus, and there is no unified standard. Therefore, a common practice is to use a set of products, manufactured by the same factory as the physical port and traffic management module, to achieve backpressure of masses of ports. Consequently, the applications of the backpressure of masses of ports are limited, or cannot be applied to a developed system.
There are other solutions to achieve backpressure in conventional art. For example, the traffic management module is accomplished by a common CPU. By using CPU to forward data, the CPU directly inquires backpressure status of channels via control channel, thus avoiding the limit of number of channels.
When CPU participates in forwarding process, the forwarding performance is limited by the CPU capacity. Moreover, the CPU also participates in control plane processing, which results in a complexity of CPU procedure and a poorer reliability of CPU. In addition, as there are too many channels, CPU cannot handle backpressure in time, i.e. CPU cannot satisfy line rate forwarding in the case that there are relatively lots of channels.